/**
 * 员工
 */
import { requestData } from '@/utils/request'

const prefix = '/sysUser'

export default {
  //新增员工
  add(data) {
    return requestData({
      url: `${prefix}/addStaff`,
      method: 'post',
      data
    })
  },
  list(params) {
    return requestData({
      url: `${prefix}/staffList`,
      method: 'get',
      params
    })
  },
  update(data) {
    return requestData({
      url: `${prefix}/updateStaff`,
      method: 'put',
      data
    })
  },
  del(id) {
    return requestData({
      url: `${prefix}/delStaff/${id}`,
      method: 'delete'
    })
  },
  get(id) {
    return requestData({
      url: `${prefix}/updateStaffPage/${id}`,
      method: 'put'
    })
  },
  forbidden(params) {
    return requestData({
      url: `${prefix}/forbidden`,
      method: 'get',
      params
    })
  },
  liftBan(params) {
    return requestData({
      url: `${prefix}/liftBan`,
      method: 'get',
      params
    })
  }
}
